<toolbar id="toolbar">
<form id="order_search" class="form-horizontal">
		<div class="filter-groups">
			<div class="control-group">
				<label class="control-label">客服微信号</label>
				<div class="controls">
					<select name="weixin" id="sel_users" style="width:150px;">
					  <option value="">全部</option>
		              <foreach name="weixin" item="item">
						<option value="{$item.id}">{$item.weixin}</option>
					  </foreach>
					</select>
				</div>
			</div>
		</div>
		<div class="filter-groups">
			<div class="control-group">
					<label class="control-label" style="width:70px;">服务态度</label>
					<div class="controls" style="margin-left:70px;">
						<select name="attitude" style="width:150px;" >
							<option value="" >全部</option>
							<option value="5">五颗星</option>
							<option value="4">四颗星</option>
							<option value="3">三颗星</option>
							<option value="2">二颗星</option>
							<option value="1">一颗星</option>
							<option value="0">未评价</option>
						</select>
					</div>
			</div>
		</div>
		<div class="filter-groups">
			<div class="control-group">
			<label class="control-label">创建时间</label>
			<div class="controls">
				<div class="input-append date" data-format="yyyy-MM-dd hh:mm:ss" >
					<input type="text" name="start_date" value="{$start_date}">
					<span class="add-on"><i class="icon-th"></i></span>
				</div>
				至
				<div class="input-append date" data-format="yyyy-MM-dd hh:mm:ss">
					<input type="text" name="end_date" value="{$end_date}"">
					<span class="add-on"><i class="icon-th"></i></span>
				</div>
			</div>
			</div>
		</div>
</form> 
</toolbar>

<!--表单 -->
<table id="table" data-toggle="gridview" class="table table-hover" data-url="__URL__" data-toolbar="#toolbar"  data-page-list="[1, 10, 25, 50, All]">
    <thead>
		<tr>
			<th data-field="kf_weixin" data-width="80">客服微信号</th>
			<th data-field="attitude" data-width="50" data-align="center" data-formatter="formatter_attitude">服务态度</th>
			<th data-field="message" data-width="200" data-align="center">投诉</th>
			<th data-field="created" data-width="110" data-align="center">创建时间</th>
			<th data-field="evaluate_time" data-width="110" data-align="center">评价时间</th>
		</tr>
	</thead>
</table>

<script type="text/javascript" src="//cdn.bootcss.com/select2/4.0.3/js/select2.min.js"></script>
<link rel="stylesheet" href="//cdn.bootcss.com/select2/4.0.3/css/select2.min.css">

<script>
var attitude = {"5":"五颗星", "4":"四颗星","3":"三颗星","2":"二颗星","1":"一颗星","0":"未评价"};
function formatter_attitude(val, row, index){
		return '<span>'+attitude[val]+'</span>'
}
$("#sel_users").select2();
</script>
